﻿@model TicketMaster.Web.Models.AddRoute

@{
    ViewBag.Title = "Добави Маршрут";
}

<h2>Добави Маршрут</h2>
<hr/>


@using (Html.BeginForm("SaveRoute", "Reservation", FormMethod.Post))
{
    @Html.AntiForgeryToken()

    <div class="form-horizontal">
        @Html.ValidationSummary(true, "", new { @class = "text-danger" })
        
        <div class="form-group">
            @Html.LabelFor(x => x.FromCities, "Начален град")
            @Html.DropDownListFor(x => x.FromCityID, Model.FromCities, "")
            @Html.ValidationMessageFor(x => x.FromCityID)
        </div>

        <div class="form-gourp">
            @Html.LabelFor(x => x.ToCities)
            @Html.DropDownListFor(x => x.ToCityID, Model.FromCities, "")
            @Html.ValidationMessageFor(x => x.FromCityID)
        </div>
        <br/>
        <div class="form-group">
            @Html.LabelFor(model => model.Distance, "Разстояние", new { style = "float:left"})
            <div class="col-md-10">
                @Html.EditorFor(model => model.Distance, new { htmlAttributes = new { @class = "form-control" } })
                @Html.ValidationMessageFor(model => model.Distance, "", new { @class = "text-danger" })
            </div>
        </div>

        <div class="form-group">
            <div class="col-md-offset-2 col-md-10">
                <input type="submit" value="Добави" class="btn btn-default" />
            </div>
        </div>
    </div>
}
@section Scripts {
    @Scripts.Render("~/bundles/jqueryval")
}
